package com.example.video.common.config.RabbitMQ;

import org.springframework.amqp.core.*;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

/**
 * @author : yj
 */
@Configuration
public class Common {

    // 交换机
    public static final String EXCHANGE = "COMMON_EXCHANGE";

    @Bean
    public Exchange commonExchange() {
        return ExchangeBuilder.directExchange(EXCHANGE).durable(true).build();
    }


}